//
//  MBDUploadTipsViewController.swift
//  MasterBoy
//
//  Created by kyson on 2023/4/10.
//

import Foundation

import UIKit
import WebKit
import SDCycleScrollView
import SnapKit

class MBDUploadTipsViewController : UIViewController {
    private var galleryView : SDCycleScrollView!
    
    var imageNames : Array<String>!
    
        
    override func viewDidLoad() {
        super.viewDidLoad()
        
        self.title = "设置群名"
        self.view.backgroundColor = UIColor(colorHex: 0xF4F4F4)

        //四周均不延伸
        navigationController?.navigationBar.isTranslucent = false

        galleryView = SDCycleScrollView()
        galleryView.localizationImageNamesGroup = self.imageNames
        galleryView.bannerImageViewContentMode = .scaleAspectFit
        galleryView.autoScrollTimeInterval = 3.5
        
        self.view.addSubview(galleryView)
        galleryView.snp.makeConstraints { make in
            if #available(iOS 11.0, *) {
                //设置视图的安全区域
                make.top.equalTo(view.snp.top).offset(65)
            } else {
                make.top.equalTo(self.view).offset(65)
            }

            make.left.equalTo(self.view)
            make.right.equalTo(self.view)
            make.bottom.equalTo(self.view).offset(-125)
        }
        
        
//        webView = WKWebView(frame:UIScreen.main.bounds, configuration: WKWebViewConfiguration())
//        webView.allowsBackForwardNavigationGestures = true;
//
//        self.view.addSubview(webView)
//
//        let url = Bundle.main.url(forResource: "generator", withExtension: "html")
//        if(nil != url) {
//            webView.loadFileURL(url!, allowingReadAccessTo: Bundle.main.bundleURL)
//        }
        
    }
    
//    override func viewWillAppear(_ animated: Bool) {
//        super.viewWillAppear(animated)
//        self.navigationController?.setNavigationBarHidden(true, animated: true)
//    }
//
//    override func viewWillDisappear(_ animated: Bool) {
//        self.navigationController?.setNavigationBarHidden(false, animated: true)
//        super.viewWillDisappear(animated)
//    }
    
}
